----------

-- procedure dss_select_14
-- uses: tenthou, fourmill
-- might use index on: tenthou.t_signed, tenthou.t_name, fourmill.t_name
-- 400 ra physical reads/sec, 1000 read aheads/sec into cache, 60% on 1 cpu
-- big ping-pong effect on read-ahead thread (moving between these two tables on the disk?)
-- lots of tempdb and log writes 
-- I think this is doing a distinct on all of fourmill before anything else
-- orig:	select count(distinct fourmill.t_name)

--create proc dss_select_14 as
--	select count(fourmill.t_name)
--	from fourmill, tenthou
--	where fourmill.t_name = tenthou.t_name
--	and tenthou.t_key between 0 and 100
--go

-- This guy is bad news. Lots of either tempdb or log writes, and no
--   finish in sight. Unindexed fourmill scan gives db problems.
